﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Space
{
    public class LaserGun : Gun
    {
        public LaserGun(Ship ship) : base(ship) { }


        public Laser Laser { get; set; }

        public override void Fire()
        {
            Laser m = new Laser(Ship)
            {
                Position = this.Position,
                Target = this.Target,

                Range = this.Range,

                Damage = Laser.Damage,
                LifeTime = Laser.LifeTime,
                MaxThickness = Laser.MaxThickness
            };
            Game.Services.GetService<IData>().AddWeapon(m);

            base.Fire();
        }
    }
}
